home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The X-Philes (2nd Revision)
/
The X-Philes Number 1 (1995).iso
/
xphiles
/
hp48hor1
/
hack.doc
< prev
next >
Wrap
Text File
|
1995-03-31
|
4KB
|
64 lines
HACK, 6 interesting (and dangerous) system-level routines by various authors.
Documentation by Joe Horn.
Uses Rick Grevelle's HACKIT library.
Some of these programs can easily cause a Memory Clear if not used
carefully. Follow these instructions closely, and be sure to backup
your memory before experimenting with these tools.
úÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
STRIP: Strips the << and >> off the program in level 1.
By Conrad Winchester.
Argument: Program object with << and >> delimiters.
Caution: STRIP does not check, it just runs, removing the second
five and second-to-last five nibs of the object in level 1. If you
give it something other than a program, you may get a Memory Clear.
PACK: Packs a program's SYSEVALs into "External" form.
By Joe Horn.
Changes all << #nnnnn SYSEVAL >> pairs in a program into the single
2.5-byte System RPL object equivalent to that SYSEVAL. Also works on
lists. See PACK.DOC on EduCALC Goodies Disk #2 for details.
FNXT: Find Next. Searches ROM/RAM for any hex digits.
Input: #search, #start, any.
Level 1 is DROPped and SYSRCLed when search terminates, which allows
repeated pressing of FNXT. Notice that the argument on level 3 is the
binary number to look for, immediately followed by the number of digits
to look for (minus 1!), which allows you to look for leading zeros.
(#1237 looks for the 8 digits 00000123.)
Example: Code objects begin with #02DCCh. That's 5 hex digits, so
add the digit "4" (one less than 5) to it: #02DCC4h. (Leading zeros do
not need to be typed, of course). To look for all the Code objects in
the operating system (starting at address #0h), type: #2DCC4h #0h #0h
FNXT. Pressing FNXT again finds the next one, etc.
Note: If you want speed and have a PC handy, don't use FNXT; use the
SEARCH command in Derek Nickel's Voyager program.
PRCL: Recalls contents of an entire port to the stack.
Argument: Port number (real) 0, 1 or 2.
Example: 1 PRCL yields the contents of port 1 on the stack.
Note: The "objects" on the stack are only poiners, not yet NEWOB'd,
so you can recall the "contents" of a very large card into a very
little amount of MEM. However, most operations on these will perform a
NEWOB (if there is sufficient MEM), such as STO. You can find the
address of port objects, however, by using ADDR after PRCL.
->RPN: Convert algebraic object into equivalent RPN object (list).
By Joe Horn.
Example: '1+2*3+4' ->RPN --> { 1 2 3 * + 4 + }. (Try EVAL).
RPN->: Convert RPN object (list) into equivalent algebraic object.
By Joe Horn.
Example: { 1 2 3 * + 4 + } RPN-> --> '1+2*3+4'. (Try EVAL).
Caution: Converting non-well-formed "RPN objects" into algebraics
will either result in an 'Invalid Expression' or 'UNKNOWN' on the
stack, which will evaluate the same as the list before conversion; or
in Memory Clear (in extreme cases). For safety's sake, only use lists
containing ->RPN outputs, or similar. Things like { << 5 >> } are not
meaningful and tempt Murphy's Law.
àÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄù